import React from 'react'
import { useContext } from 'react';
import { Context } from '../../context';

export default () => {
  const AppText = useContext(Context)

  const changeTrue = () => {
    AppText.dispatch({
      type:'TRUE',
      payload:{},
    })
  };

  const changeFalse = () => {
    AppText.dispatch({
      type:'FALSE',
      payload:{},
    })
  }

  return (
    <div>
      <button onClick={ changeTrue }>TRUE</button>
      <button onClick={ changeFalse }>FALSE</button>
    </div>
  )
}

